package com.jrx.anytxn.investor.dto.common;

import com.jrx.anytxn.common.constant.RegexConstant;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;
import java.io.Serializable;

public class CommonReq implements Serializable {
    /**
     * 交易流水号
    **/
    @ApiModelProperty(value = "流水号",required = true)
    @Size(max=32, message = "交易流水号必须小于32位")
    @Pattern(regexp = RegexConstant.ALL_CHARSET_AND_NUMBER, message = "流水号只能是英文字母和数字组成且不可为空")
    private String seqNo;
    /**
     * 租户ID
     **/
    @ApiModelProperty(value = "租戶id",required = true)
    @Size(max=4, message = "租戶id不能超过4位")
    @NotEmpty(message = "租戶id不可空")
    private String tenantId;
    /**
     * 用户编号
     */
    @Size(max=20, message = "用户编号不能超过20位")
    @ApiModelProperty(value = "用户编号",required = true)
    @NotEmpty(message = "用户编号不能为空")
    private String userId;
    /**
     * 渠道号
     */
    @ApiModelProperty(value = "渠道号", required = true)
    @Size(max=32, message = "渠道号不能超过32位")
    @NotEmpty(message = "渠道号不能为空")
    private String channel;

    public String getSeqNo() {
        return seqNo;
    }

    public void setSeqNo(String seqNo) {
        this.seqNo = seqNo;
    }

    /**
     * 获取用户编号
     **/
    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    /**
     * 获取渠道号
     **/
    public String getChannel() {
        return channel;
    }

    public void setChannel(String channel) {
        this.channel = channel;
    }

    public String getTenantId() {
        return tenantId;
    }

    public void setTenantId(String tenantId) {
        this.tenantId = tenantId;
    }
}
